package com.notion.algorithms.datastructures.graph;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;

import com.notion.algorithms.datastructures.graph.Edge;
import com.notion.algorithms.datastructures.graph.Vertex;

/**
 * Immutable class
 * @author samurai
 *
 */
public final class Cluster {

	//To fetch all verteices belonging to this cluster
	private Set<Vertex> clusteredVertex = new HashSet<Vertex>();

	public int getClusterVertexCount(){		
		return clusteredVertex.size();
	}

	

	public Cluster(Vertex v){
		clusteredVertex.add(v);
		Clusters.addVertexCluster(v, this);
	}

/*	public void addEdgeToCluster(ClusteredEdge edge){
		this.clusterEdges.add(edge);
		this.clusteredVertex.add(edge.getVertex1());
		this.clusteredVertex.add(edge.getVertex2());
	}*/

	
	public void addVertexToCluster(Vertex v){
		clusteredVertex.add(v);
	}




	public Set<Vertex> getClusterVertices(){
		return clusteredVertex;
	}
}
